package com.psjj.mall.exception;

/**
 * @Auther:云尚学Java
 * 异常枚举类
 */
public enum  MallExceptionEnum {
    NEED_USERNAME(10001,"用户密码不能为空"),
    NEED_PASSWORD(10002,"用户密码不能为空"),
    NEED_PASSWORD_LENGTH(10003,"用户密码长度不能小于3"),
    INSERT_FAILED(1004,"插入数据失败"),
    NAME_EXISTS(10005,"名字已经存在"),
    SYSTEM_ERROR(1006,"系统异常");
    MallExceptionEnum(Integer status,String msg){
        this.status=status;
        this.msg=msg;
    }
    //异常状态码
    private Integer status;
    //异常状态信息
    private String msg;

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }
}
